<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreatePhpTestTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    // database/migrations/xxxx_xx_xx_create_php_test_table.php
    public function up()
    {
        Schema::create('php_test', function (Blueprint $table) {
            $table->id();
            $table->string('name');
            $table->integer('age');
            $table->date('birth_date'); // 注意字段名应该是birth_date而不是brith_date
            $table->timestamps();
        });
    }

    public function down()
    {
        Schema::dropIfExists('php_test');
    }



}
